<?php $this->display("objects/breadcrumbs") ?>

<h2><?php _e($object['title']) ?></h2>
<p id="objdesc"><strong><?php _e($object['description']) ?></strong></p>

<?php echo $object['content'] ?>

<?php if ($showingtag): ?>
	<p><em>There 
	<?php if ($tagobjectcount > 1): ?>are <?php echo (int)$tagobjectcount ?> entries
	<?php elseif ($tagobjectcount == 1): ?>is 1 entry
	<?php else: ?>are no entries<?php endif; ?>
	 tagged <strong><?php _e($showingtag) ?></strong>. <a href="<?php echo Gene::makeLink($object) ?>">Show all entries</a>.</em></p>
<?php endif; ?>

<div class="hfeed">
<?php if (count($childs)): ?>
	<?php foreach ($childs as $i): ?>
		<?php if (checkPermission($i, "view")): ?>
			<?php $this->display("objects/blogentry/listing", array("object" => $i)) ?>
		<?php elseif (getProperty("notifyNoView")): ?>
			<p>An entry here has been hidden because you do not have priviledges to view it.</p>
		<?php endif; ?>
	<?php endforeach; ?>
<?php else: ?>
	<p><em>There are currently no blog entries.</em></p>
<?php endif; ?>
</div>

<?php if ($showingtag): ?>
	<?php echo getPager(array(
		"object" => $object,
		"numpages" => $numpages,
		"currentpage" => $pagenum,
		"showingtag" => $showingtag
	)) ?>
<?php else: ?>
	<?php echo getPager(array(
		"object" => $object,
		"numpages" => $numpages,
		"currentpage" => $pagenum,
	)) ?>
<?php endif; ?>

<?php if (checkPermission($object, "write")): ?>
	<?php $this->display("objects/blogentry/create"); ?>
<?php endif; ?>